#ifndef _MyRedisD_H_
#define _MyRedisD_H_

#include "NIOServer.h"
#include "SkipList.h"


struct RedisData{
    string operate;
    string key;
    string val;

};

// 继承NIOServer
class MyRedisD: public NIOServer{
private:
    skiplist<string, string> skp;

public:
    MyRedisD(std::string host, int port, int thread_pool_num=8);
    int unpack_and_pack(char *&buf, int offset, int fd) override ;
};

void testMyRedisD();

#endif // _MyRedisD_H_